Skip to content

Conversation

@quic-akaryaki
Copy link
Contributor

No description provided.

@quic-akaryaki quic-akaryaki force-pushed the lto-options-2 branch 3 times, most recently from 0e3fe1c to 5f1c4cc Compare January 8, 2026 20:02
@quic-akaryaki quic-akaryaki force-pushed the lto-options-2 branch 2 times, most recently from 2ddb004 to efde665 Compare January 16, 2026 21:51
ObjectLinker::doLto() had convoluted flow, duplicated pieces of code
in different branches, etc. Simplify and clarify it.

There is no functional change, except when both `lto-asm-file` and
`lto-output-file` specified, on Hexagon only, a misleading message
about using the asm file is not printed. When `lto-output-file`,
the assembly inputs are ignored, this did not change, and the message
was incorrect.

Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
@quic-akaryaki quic-akaryaki marked this pull request as ready for review January 20, 2026 21:25
@quic-akaryaki quic-akaryaki changed the title Refactor LTO compilation Adding LTO options Jan 20, 2026
@quic-akaryaki quic-akaryaki marked this pull request as draft January 20, 2026 23:09
Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
These options have aliases:

--plugin-opt=cs-profile-generate
--plugin-opt=cs-profile-path=

Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
--lto-obj-path will work differently than in lld. In lld, it creates
copies of LTO output files, which means with `-save-temps` each object
file will be written twice. Instead, we will redirect output files
to the location specified by `--lto-obj-path`, which means these files
will not be written to the `-save-temps` location if it is specified.

Signed-off-by: Alexey Karyakin <akaryaki@qti.qualcomm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants